package cn.like.entity;

import cn.like.base.BaseEntity;
import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 角色分配
 * 账号角色绑定(AuthUserRole)表实体类
 *
 * @author like
 * @since 2021-07-08 15:59:14
 */
@Data
@TableName("auth_user_role")
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "角色分配 账号角色绑定")
@SuppressWarnings("serial")
public class AuthUserRole extends BaseEntity<AuthUserRole> {
	
	public static final String id_col_name = "id";
	public static final String roleId_col_name = "role_id";
	public static final String userId_col_name = "user_id";
	public static final String createUser_col_name = "create_user";
	public static final String createTime_col_name = "create_time";
	
	@TableId(value = "id", type = IdType.ASSIGN_ID)
	@ApiModelProperty(value = "主键")
	@NotNull(message = "id不能为空")
	private Long id;
	
	/**
	 * 角色ID
	 * #c_auth_role
	 */
	@ApiModelProperty(value = "角色ID#c_auth_role")
	private Long roleId;
	
	/**
	 * 用户ID
	 * #c_core_accou
	 */
	@ApiModelProperty(value = "用户ID#c_core_accou")
	private Long userId;
	
	/**
	 * 创建人id
	 */
	@ApiModelProperty(value = "创建人id")
	@TableField(fill = FieldFill.INSERT)
	private Long createUser;
	
	/**
	 * 创建时间
	 */
	@ApiModelProperty(value = "创建时间")
	@TableField(fill = FieldFill.INSERT)
	private LocalDateTime createTime;
}